import java.io.*;
import java.util.*;

public class  Transaction implements Serializable, Comparable<Transaction>{

    private static final long serialVersionUID = 1;
    public final int transactionID;

    private int memberID;
    private int itemID;
    private int quantity;
    private String date;

    public Transaction(int transactionID, int memberID, int itemID, int quantity, String date) {
	this.transactionID = transactionID;
	this.memberID = memberID;
	this.itemID = itemID;
	this.quantity = quantity;
	this.date = date;
   }

    public int compareTo(Transaction other) {
	return (this.transactionID - other.transactionID);
    }

    public void setMemberID(int input) {
	memberID = input;
    }
    public void setItemID(int input) {
	itemID = input;
    }
    public void quantity(int input) {
	quantity = input;
    }
    public void setDate(String input) {
	date = input;
    }

    public int getMemberID() {
	return memberID;
    }
   public int getItemID() {
	return itemID;
    }
   public int getQuantity() {
	return quantity;
    }
   public String getDate() {
	return date;
    }
}